<!DOCTYPE html>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>处理字符串</title>
</head>
<body>
<h2>处理字符串</h2>
<%
    // 获取 inputString.jsp 提交的字符串
    String inputString = request.getParameter("inputString");

    // 计算字符串的长度
    int length = inputString.length();
%>
<p>输入的字符串是: <%= inputString %></p>
<p>字符串的长度是: <%= length %></p>
</body>
</html>
